package com.swust.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller//代表着个类会被spring接管，被注解的这个类，如果返回值是String，并且有具体的页面，那么就会被属兔解析器解析
public class ControllerTest2 {
    @RequestMapping("/t2")
    public String test1(Model model){

        model.addAttribute("msg","ControllerTest2");
        return "test";
    }
}
